﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Data;
using KPIS.GERP.GHRMS.DAL;

namespace KPIS.GERP.GHRMS.BLL
{
    public class TrainingScholarshipsRequestsBLL
    {
        ConvertNullable cn = new ConvertNullable();
        private static readonly TrainingScholarshipsRequestsDAL dal = new TrainingScholarshipsRequestsDAL();

        public DataSet GetDatacbEduInstitutes(string edu_ins_seq)
        {
            Nullable<int> iedu_ins_seq = cn.ConvertNullInt(edu_ins_seq);
            return dal.GetDatacbEduInstitutes(iedu_ins_seq);
        }
        public DataSet GetDataSchReq(string emp_seq, string seq)
        {
            Nullable<int> iemp_seq = cn.ConvertNullInt(emp_seq);
            Nullable<int> iseq = cn.ConvertNullInt(seq);
            return dal.GetDataSchReq(iemp_seq, iseq);
        }
        public void InsertSchReq(int emp_seq, int scholar_seq, int edu_ins_seq, int edu_major_seq, string teacher_name
                            , string response_no, DateTime response_date, DateTime date_start, int duration_month
                            , int duration_year, int amount_request, string created_by)
        {
            Nullable<int> icreated_by = cn.ConvertNullInt(created_by);
            dal.InsertSchReq(emp_seq, scholar_seq, edu_ins_seq, edu_major_seq, teacher_name,response_no
                            , response_date, date_start, duration_month, duration_year, amount_request, icreated_by);
        }
    }
}
